/*
 * Manager.hpp
 *
 *  Created on: Jan 24, 2015
 *      Author: wasp
 */

#include "../applicationui.hpp"
#include "Carrier.hpp"
#include <qobjectdefs.h>
class QNetworkReply;
namespace de
{
    namespace heimweghelden
    {
        namespace network
        {
            class Manager : public QObject
            {
                Q_OBJECT
            public:
                static Manager* getInstance(QObject* parent = NULL);
                static void drop();
                static Manager* _instance;
                void publishUserinfo();
                void setApp(ApplicationUI* a) { app = a; }
                void request(Carrier* carrier);
            public slots:
                void onPublishUserinfoFinished();
            private:
                Manager(QObject* parent = NULL);
                virtual ~Manager();
                ApplicationUI* app;
                QNetworkReply* reply;
            };

        } /* namespace network */
    } /* namespace heimweghelden */
} /* namespace de */

